import request from '../utils/request';

export async function login(data) {
  return request({
    url: '/user/login',
    method: 'POST',
    data
  })
}

export async function register(data) {
  return request({
    url: '/user/register',
    method: 'POST',
    data
  })
}

export async function oauthLogin(data) {
  return request({
    url: '/user/oauthLogin',
    method: 'POST',
    data
  })
}

export async function updateUserInfo(data) {
  return request({
    url: '/user/update',
    method: 'POST',
    data
  })
}

export async function getSchoolTree() {
  return request({
    url: '/school/getTree',
    method: 'GET',
  })
}

export async function authorize(data) {
  return request({
    url: '/user/authorize',
    method: 'POST',
	data
  })
}






